home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
archiver
/
pax2exe.zip
/
PAX.MAN
< prev
next >
Wrap
Text File
|
1990-02-25
|
16KB
|
463 lines
PAX(1) UNIX Programmer's Manual PAX(1)
NAME
pax - portable archive exchange
SYNOPSIS
pax [-cimopuvy] [-f archive] [-s replstr] [-t device] [pat-
tern...]
pax -r [-cimnopuvy] [-f archive] [-s replstr] [-t device]
[pattern...]
pax -w [-adimuvy] [-b blocking] [-f archive] [-s replstr]
[-t device] [-x format] [pathname...]
pax -rw [-ilmopuvy] [-s replstr] [pathname...] directory
DESCRIPTION
Pax reads and writes archive files which conform to the
Archive/Interchange File Format specified in IEEE Std.
1003.1-1988. Pax can also read, but not write, a number of
other file formats in addition to those specified in the
Archive/Interchange File Format description. Support for
these traditional file formats, such as V7 tar and System V
binary cpio format archives, is provided for backward compa-
tibility and to maximize portability.
Pax will also support traditional cpio and System V tar
interfaces if invoked with the name "cpio" or "tar" respec-
tively. See the cpio(1) or tar(1) manual pages for more
details.
Combinations of the -r and -w command line arguments specify
whether pax will read, write or list the contents of the
specified archive, or move the specified files to another
directory.
The command line arguments are:
-w writes the files and directories specified by pathname
operands to the standard output together with the path-
name and status information prescribed by the archive
format used. A directory pathname operand refers to
the files and (recursively) subdirectories of that
directory. If no pathname operands are given, then the
standard input is read to get a list of pathnames to
copy, one pathname per line. In this case, only those
pathnames appearing on the standard input are copied.
-r Pax reads an archive file from the standard input.
Only files with names that match any of the pattern
operands are selected for extraction. The selected
files are conditionally created and copied relative to
the current directory tree, subject to the options
Printed 2/26/90 1
PAX(1) UNIX Programmer's Manual PAX(1)
described below. By default, the owner and group of
selected files will be that of the invoking process,
and the permissions and modification times will be the
sames as those in the archive.
The supported archive formats are automatically
detected on input. The default output format is ustar,
but may be overridden by the -x format option described
below.
-rw Pax reads the files and directories named in the path-
name operands and copies them to the destination direc-
tory. A directory pathname operand refers to the files
and (recursively) subdirectories of that directory. If
no pathname operands are given, the standard input is
read to get a list of pathnames to copy, one pathname
per line. In this case, only those pathnames appearing
on the standard input are copied. The directory named
by the directory operand must exist and have the proper
permissions before the copy can occur.
If neither the -r or -w options are given, then pax will
list the contents of the specified archive. In this mode,
pax lists normal files one per line, hard link pathnames as
pathname == linkname
and symbolic link pathnames (if supported by the implementa-
tion) as
pathname -> linkname
where pathname is the name of the file being extracted, and
linkname is the name of a file which appeared earlier in the
archive.
If the -v option is specified, then pax list normal path-
names in the same format used by the ls utility with the -l
option. Hard links are shown as
<ls -l listing> == linkname
and symbolic links (if supported) are shown as
<ls -l listing> -> linkname
Pax is capable of reading and writing archives which span
multiple physical volumes. Upon detecting an end of medium
on an archive which is not yet completed, pax will prompt
the user for the next volume of the archive and will allow
the user to specify the location of the next volume.
Printed 2/26/90 2
PAX(1) UNIX Programmer's Manual PAX(1)
Options
The following options are available:
-a The files specified by pathname are appended to
the specified archive.
-b blocking
Block the output at blocking bytes per write to
the archive file. A k suffix multiplies blocking
by 1024, a b suffix multiplies blocking by 512 and
a m suffix multiplies blocking by 1048576 (1 mega-
byte). For machines with 16-bit int's (VAXen,
XENIX-286, etc.), the maximum buffer size is 32k-
1. If not specified, blocking is automatically
determined on input and is ignored for -rw.
-c Complement the match sense of the pattern
operands.
-d Intermediate directories not explicitly listed in
the archive are not created. This option is
ignored unless the -r option is specified.
-f archive
The archive option specifies the pathname of the
input or output archive, overriding the default of
standard input for -r or standard output for -w.
-i Interactively rename files. Substitutions speci-
fied by -s options (described below) are performed
before requesting the new file name from the user.
A file is skipped if an empty line is entered and
pax exits with an exit status of 0 if EOF is
encountered.
-l Files are linked rather than copied when possible.
-m File modification times are not retained.
-n When -r is specified, but -w is not, the pattern
arguments are treated as ordinary file names.
Only the first occurrence of each of these files
in the input archive is read. The pax utility
exits with a zero exit status after all files in
the list have been read. If one or more files in
the list is not found, pax writes a diagnostic to
standard error for each of the files and exits
with a non-zero exit status. the file names are
compared before any of the -i, -s, or -y options
are applied.
-o Restore file ownership as specified in the
Printed 2/26/90 3
PAX(1) UNIX Programmer's Manual PAX(1)
archive. The invoking process must have appropri-
ate privileges to accomplish this.
-p Preserve the access time of the input files after
they have been copied.
-s replstr
File names are modified according to the substitu-
tion expression using the syntax of ed(1) as
shown:
-s /old/new/[gp]
Any non null character may be used as a delimiter
(a / is used here as an example). Multiple -s
expressions may be specified; the expressions are
applied in the order specified termina